﻿<%@ Import Namespace="VirtuosoDal.Entities" %>

    <% if ((this.ViewData["GeoLabelsDescriptions"] as IList<GeoLabelDescription>).Count == 0)
       {
    %>
            <p class="message">
            <%= ViewStrings.EventsStrings.YouHaveNoLabeledLocations %>
            </p>
    <%
        }
       else
       {
    %>
        <div class="window">
    <%
        foreach (
           GeoLabelDescription geoLabelDescription in
              this.ViewData["GeoLabelsDescriptions"] as IEnumerable<GeoLabelDescription>)
        {
    %>

    <p><strong> &bull; <%=geoLabelDescription.Label%> : </strong><%= geoLabelDescription.CityName %><% if (!String.IsNullOrEmpty(geoLabelDescription.PlaceName))
                                                                                                       { %>, <%= geoLabelDescription.PlaceName%><% } %>
    <a href="#" onclick="useLabeledPlace(<%= geoLabelDescription.LabelUri.Split(new[] { "geolabels/" }, StringSplitOptions.RemoveEmptyEntries)[1] %>, 
            '<%= geoLabelDescription.CityUri %>', 
            '<%= geoLabelDescription.CityName %>', 
            '<%= geoLabelDescription.PlaceUri %>', 
            '<%= geoLabelDescription.PlaceName %>')">
                <%= ViewStrings.EventsStrings.Choose %></a> </p>

    <%
        }
     %>
     </div>
     <%
       }
    %>
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>